package com.malleurekaclient.malleurekaclient.controller;

import org.hibernate.validator.constraints.ParameterScriptAssert;
import org.springframework.web.bind.annotation.*;

import javax.websocket.server.PathParam;

/**
 * Created with IntelliJ IDEA.
 *
 * @Author: where
 * @Date: 2022/07/21/15:05
 * @Description:
 */
@RestController("eureka")
@RequestMapping("/eureka")
@ResponseBody
public class TestController {

    @GetMapping("/{id}")
    public String test01 (@PathVariable int id) {
        System.out.println("GET请求");
        return "hello world!!" + id;
    }

    @PostMapping
    public String testo2() {
        System.out.println("post请求");
        return "postTestSuccess";
    }

}
